1. Field of the Invention
The present invention relates to a data input/output circuit which is used for transferring data to or from device or circuit being connected to an external, and more specifically, relates to a data input/output circuit capable of being applied to the devices or circuits in which data formats are different from each other.
2. Description of the Prior Art
In general, the greater part of original information source such as sound or image being in existence in the circumstances is analog signal. A system for processing the analog signal in a digital manner is called as a digital signal processing system (DSP system).
Recently, as technology for making a digital circuitry into an LSI rapidly progresses, it becomes easy to implement the DSP system on a single chip of a semiconductor device. Furthermore, such a DSP system has many advantages as that it is possible to process with accuracy higher than that of processing in an analog manner, that a desired characteristic can be equally and stably obtained by setting suitable parameters therein, and that it is possible to make a circuit into adjustment-free circuit, and therefore, the DSP system becomes to be rapidly put to practical use. In addition, application domain of the DSP system is extended, and the DSP system is widely utilized in a system for processing signals such as a sound signal, communication signal, measurement signal, image signal, earthquake wave signal, underwater sound signal, and etc.
Furthermore, in a field of audio equipments such as a CD (compact disk) player and a DAT (digital audio tape) player, as digital processing of an audio signal progresses, the DSP system which processes the audio signal in a digital manner is put into practice.
in such a DSP system, since the signal to be processed is digital data, it is necessary to be provided with a data input/output circuit for making data transfer of the digital data from or to an A-D converting circuit which converts the analog signal to digital data or a circuit which fetches the digital data from recording media, or a D-A converting circuit which converts the processed digital data to the analog signal.
In general, for transferring the digital data between the DSP system and the other circuit, a serial data transferring technique is used due to a limit of the number of connecting wires or leads. More specifically, in a conventional data input/output circuit, a shift register having the same bit number as the data to be processed is used, and the data being sent from an external is sequentially stored in the shift register in accordance with synchronous clock signals and the stored data is outputted onto a data bus in a bit-parallel fashion, or the data being sent onto the data bus is inputted to the shift register in a bit-parallel fashion in accordance with synchronous clock signals and the stored data is outputted to an external in a bit-serial fashion.
However, in the conventional data input/output circuit, since the shift register is designed so as to fit a format of the data to be processed, the conventional data input/output circuit cannot be applied to the other devices or circuits in which the formats of the data are different from each other. Therefore, it is necessary to newly design the data input/output circuit to fit the different format of the data to be processed.
For example, in an audio system such as a CD system or a DAT system, or other PCM processing system, the data formats as shown in FIG. 2 are used. In FIG. 2, (A) and (B) show the case where the whole data length is 16 bits and the audio signal data is also 16 bits, and a transfer order of FIG. 2 (A) is "MSB first" and a transfer order of FIG. 2 (B) is "LSB first". Meanwhile, the term "MSB first" means a mode where the most significant bit (MSB) is to be inputted or outputted first, and the term "LSB first" means a mode where the least significant bit (LSB) is to be inputted or outputted first. FIG. 2 (C) and (D) show the case where the whole data length is 24 bits and the audio signal data is 16 bits and other information bits such as control data is included in addition to the audio signal data, and FIG. 2 (C) shows the case of MSB first and FIG. 2 (D) shows the case of LSB first. FIG. 2 (E) and (F) show the case where the whole data length and the audio signal data are respectively 24 bits, and FIG. 2 (E) shows the case of MSB first and FIG. 2 (F) shows the case of LSB first. FIG. 2 (G) and (H) show the case where the whole data length is 32 bits and the audio signal data is 24 bits, and FIG. 2 (G) shows the case of MSB first and FIG. 2 (H) shows the case of LSB first.
In the conventional data input/output circuit, it is impossible to apply the DSP system to the systems in which the data formats are different from each other as described above.